package lib.gui;

import java.util.Vector;

import net.rim.device.api.ui.Color;
import net.rim.device.api.ui.decor.BackgroundFactory;

import lib.classes.Profile;
import lib.classes.RichListNode;

public class FriendsScreen extends Page
{
	Profile selected;
	public FriendsScreen(Vector profiles) 
	{
		super("My Connects");
		int zcolor = 0;
		for(int i=0; i < profiles.size(); i++)
		{
			RichListNode friend = new RichListNode((Profile)profiles.elementAt(i), this);
			if(zcolor%2==0)
        	{
        		friend.setRealBkg(BackgroundFactory.createSolidBackground(Color.WHITESMOKE));
        	}else
        	{
        		friend.setRealBkg(BackgroundFactory.createSolidBackground(Color.LIGHTCYAN));
        	}
			add(friend.field);
        	zcolor++;
		}
	}
	
	public void setSelectedProfile(Profile p)
	{
		selected = p;
	}

}
